Platform Explorer / Nuxeo Platform LTS 2016 8.10

Contribution org.nuxeo.ecm.platform.video.tools.commandlines--command

This contribution is part of XML component org.nuxeo.ecm.platform.video.tools.commandlines inside nuxeo-platform-video-core-8.10.jar /OSGI-INF/video-tools-commandlines-contrib.xml

Extension Point

Extension point command of component CommandLineExecutorComponent.

Contributed Items

  • <command enabled="true" name="videoClosedCaptionsExtractor">
          <commandLine>ccextractor</commandLine>
          <parameterString>#{sourceFilePath} -out=#{outFormat} -trim -o #{outFilePath}
          </parameterString>
          <installationDirective>You need to install ccextractor.</installationDirective>
        </command>
  • <command enabled="true" name="videoPartClosedCaptionsExtractor">
          <commandLine>ccextractor</commandLine>
          <parameterString>#{sourceFilePath} -out=#{outFormat} -startat #{startAt} -endat #{endAt} -trim -o #{outFilePath}
          </parameterString>
          <installationDirective>You need to install ccextractor.</installationDirective>
        </command>
  • <command enabled="true" name="videoConcat">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -f concat -safe 0 -i #{listFilePath} -c copy #{outFilePath}</parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>
  • <command enabled="true" name="videoSlicerByCopy">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -i #{sourceFilePath} -ss #{startAt} -t #{duration} -c copy #{outFilePath}</parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>
  • <command enabled="true" name="videoSlicer">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -i #{sourceFilePath} -ss #{startAt} -t #{duration} #{outFilePath}</parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>
  • <command enabled="true" name="videoSlicerStartAt">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -i #{sourceFilePath} -ss #{startAt} #{outFilePath}</parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>
  • <command enabled="true" name="videoSlicerSegments">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -i #{sourceFilePath} -map 0 -c copy -f segment -segment_time #{duration} -reset_timestamps 1
            #{outFilePath}
          </parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>
  • <command enabled="true" name="videoWatermarkWithPicture">
          <commandLine>ffmpeg</commandLine>
          <parameterString>-y -i #{sourceFilePath} -i #{pictureFilePath} -filter_complex #{filterComplex} #{outFilePath}
          </parameterString>
          <installationDirective>You need to install ffmpeg.</installationDirective>
        </command>

XML Source

<extension point="command" target="org.nuxeo.ecm.platform.commandline.executor.service.CommandLineExecutorComponent">

    <command enabled="true" name="videoClosedCaptionsExtractor">
      <commandLine>ccextractor</commandLine>
      <parameterString>#{sourceFilePath} -out=#{outFormat} -trim -o #{outFilePath}
      </parameterString>
      <installationDirective>You need to install ccextractor.</installationDirective>
    </command>

    <command enabled="true" name="videoPartClosedCaptionsExtractor">
      <commandLine>ccextractor</commandLine>
      <parameterString>#{sourceFilePath} -out=#{outFormat} -startat #{startAt} -endat #{endAt} -trim -o #{outFilePath}
      </parameterString>
      <installationDirective>You need to install ccextractor.</installationDirective>
    </command>

    <command enabled="true" name="videoConcat">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -f concat -safe 0 -i #{listFilePath} -c copy #{outFilePath}</parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>

    <!-- This one is very fast, but you may miss frames. Use it when you are sure you'll get the correct cut -->
    <command enabled="true" name="videoSlicerByCopy">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -i #{sourceFilePath} -ss #{startAt} -t #{duration} -c copy #{outFilePath}</parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>

    <!-- This on is the basic slicing. It re-encodes the video, so it it is slower than videoSlicerCopy -->
    <command enabled="true" name="videoSlicer">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -i #{sourceFilePath} -ss #{startAt} -t #{duration} #{outFilePath}</parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>
  
    <!-- This enables video slicing starting from the specific time -->
    <command enabled="true" name="videoSlicerStartAt">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -i #{sourceFilePath} -ss #{startAt} #{outFilePath}</parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>

    <!-- Slices in n segment of #duration each. outFilePath is an expression
         (OUT%03d.mp4 for example) so ffmpeg creates one file/segment -->
    <command enabled="true" name="videoSlicerSegments">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -i #{sourceFilePath} -map 0 -c copy -f segment -segment_time #{duration} -reset_timestamps 1
        #{outFilePath}
      </parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>

    <!-- filterComplex is the full filter. For example: "overlay=10:10" -->
    <command enabled="true" name="videoWatermarkWithPicture">
      <commandLine>ffmpeg</commandLine>
      <parameterString>-y -i #{sourceFilePath} -i #{pictureFilePath} -filter_complex #{filterComplex} #{outFilePath}
      </parameterString>
      <installationDirective>You need to install ffmpeg.</installationDirective>
    </command>

  </extension>